from django.shortcuts import render
from django.http import HttpResponse
# Create your views here.


# 视图函数
def index(request):
    return HttpResponse('django hello')


def index_html(request):
    # 模拟在数据库中获取到数据 并渲染到页面中
    user_info = {
        'username': '顾安',
    }
    return render(request, 'book/index.html', context=user_info)
